package cn.fresh.xuanyuan.framework.common.util.string;

import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.UUID;

public class FileUtil {

    public static String createPath() {
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd");
        Date now = new Date();
        return sdf.format(now);
    }

    public static String createFileName(String suffix) {
        return UUID.randomUUID().toString().replace("-", "") + suffix;
    }

    public static String createDateFileName() {
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
        Date now = new Date();
        return sdf.format(now);
    }
}
